﻿<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@page pageEncoding="UTF-8" contentType="text/html; UTF-8" isELIgnored="false" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
<link type="text/css" rel="stylesheet" href="css/style.css">
<script type="text/javascript" src="js/jquery-1.8.3.min.js"></script>
<script type="text/javascript">
	function update() {
		var supplierID = ${supplier.supplierID};
		window.location.href = '${pageContext.request.contextPath}/supplier/updateView?supplierID='+supplierID;
	}
</script>
</head>
<body>
<c:if test="${not empty supplier}">
	<div class="main">
		<div class="optitle clearfix">
			<div class="title">
				<h3>供应商管理&gt;&gt;</h3>
			</div>
		</div>
		<div class="content">
			<table class="box">
				<tbody><tr>
					<td class="field">供应商编号：</td>
					<td>${supplier.supplierID}<input type="hidden" id="supplierID" value="${supplier.supplierID}"></td>

				</tr>
				<tr>
					<td class="field">供应商名称：</td>
					<td>${supplier.supplierName}</td>
				</tr>
				<tr>
					<td class="field">联系人：</td>
					<td>${supplier.contactPerson}</td>
				</tr>
				<tr>
					<td class="field">联系电话：</td>
					<td>${supplier.contactPhone}</td>

				</tr>
				<tr>
					<td class="field">电子邮箱：</td>
					<td>${supplier.contactEmail}</td>

				</tr>

				</tbody></table>
		</div>
		<div class="buttons">
			<input type="button" id="update" value="修改" class="input-button" onclick="update()">
			<input type="button" id="del" value="删除" class="input-button"
				   onclick="if(confirm('确定删除该客户？')){window.location='${pageContext.request.contextPath}/supplier/delete?supplierID=${supplier.supplierID}';}">
			<input type="button" id="backButton" onclick="history.back(-1)" value="返回" class="input-button">
		</div>
	</div>
</c:if>
	<script type="text/javascript" src="js/provider/view.js"></script>


</body></html>